<template>
  <PageContainer>
    <div class="text-[16px] color-333 mb-[20px] fw-bold">账户信息</div>
    <div class="flex justify-between align-start">
      <div class="info">
        <span>开户行：{{ payment_allocation_info.bank_name || '' }}</span>
        <span>收款账号（银行卡）：{{ payment_allocation_info.bank_card_number || '' }}</span>
        <span>开户支行：{{ payment_allocation_info.bank_branch_name || '' }}</span>
        <span>收款人/收款公司：{{ payment_allocation_info.payee || '' }}</span>
        <span>联系人电话：{{ payment_allocation_info.payee_mobile || '' }}</span>
      </div>
      <div>
        <el-link type="primary" @click="dialogVisible = true">变更收款账户</el-link>
      </div>
    </div>
    <el-divider style="border-top: 10px solid #f7f7f7" />
    <div class="text-[16px] color-333 mb-[20px] fw-bold">注意事项</div>
    <div class="color-999 text-[12px] line-height-loose w-[800px] attention">
      <li>
        <span class="mr-[5px]">●</span>
        在进行提现操作时，确保您的收款账户信息（如银行卡号）准确无误，并已通过平台的验证。部分平台可能会要求您输入短信验证码或进行其他形式的身份验证，以确保提现请求的真实性。
      </li>
      <li>
        <span class="mr-[5px]">●</span>
        提现后，密切关注资金的到账时间。不同平台或银行的处理速度可能有所不同，因此了解并接受可能的到账延迟是必要的。
      </li>
      <li><span class="mr-[5px]">●</span>支付订单，对账后14个工作日后，会自动转到可提现余额中。</li>
    </div>
    <el-dialog title="设置收款账号" v-model="dialogVisible" width="600px">
      <el-form class="px-[20px]" :model="payment_allocation_info" label-width="auto">
        <el-form-item label="开户行名称" required>
          <el-input v-model="payment_allocation_info.bank_name" placeholder="请输入开户行名称" />
        </el-form-item>
        <el-form-item label="开户支行名称" required>
          <el-input v-model="payment_allocation_info.bank_name" placeholder="请输入开户支行名称" />
        </el-form-item>
        <el-form-item label="银行卡号或者对公账户" required>
          <el-input v-model="payment_allocation_info.bank_name" placeholder="请输入银行卡号或者对公账户" />
        </el-form-item>
        <el-form-item label="收款人或收款公司" required>
          <el-input v-model="payment_allocation_info.bank_name" placeholder="请输入收款人或收款公司" />
        </el-form-item>
        <el-form-item label="联系人电话" required>
          <el-input v-model="payment_allocation_info.bank_name" placeholder="请输入联系人电话" />
        </el-form-item>
      </el-form>
      <template #footer>
        <div class="center">
          <el-button @click="dialogVisible = false">取消</el-button>
          <el-button type="primary" @click="dialogVisible = false">确定</el-button>
        </div>
      </template>
    </el-dialog>
  </PageContainer>
</template>

<script setup lang="ts">
defineOptions({
  name: 'PayAccount',
})
const payment_allocation_info = ref({
  bank_name: '',
  bank_card_number: '',
  bank_branch_name: '',
  payee: '',
  payee_mobile: '',
})
const dialogVisible = ref(false)
</script>

<style lang="scss" scoped>
.info {
  width: 700px;
  display: flex;
  flex-wrap: wrap;
  font-weight: 500;
  gap: 20px 0;
  > span {
    width: 350px;
    color: #666;
    font-size: 14px;
  }
}
.attention {
  > li {
    display: flex;
  }
}
</style>
